<admintpl file="header" />
</head>
<body>
<div class="wrap">
    <ul class="nav nav-tabs">
        <li><a href="{:U('indexadmin/unwanted_user')}">不借列表</a></li>
        <li class="active"><a>添加运营备注</a></li>
    </ul>
    <form method="post" class="form-horizontal js-ajax-form" action="{:U('indexadmin/operator_remark',['id'=>$user['id']])}">
        <fieldset>
            <div class="control-group">
                <label class="control-label">用户</label>
                <div class="controls">
                    <input type="text" value="{$user.name}" disabled class="disabled">
                </div>
            </div>
            <div class="control-group">
                <label class="control-label">历史备注:</label>
                <div class="controls">
                    <table class="table table-bordered">
                        <tr>
                            <th>日期</th>
                            <th>填写人</th>
                            <th>备注</th>
                            <th>操作</th>
                        </tr>
                        <foreach name="list" item="vo">
                            <tr>
                                <td>{$vo.create_time|date="Y-m-d H:i:s",###}</td>
                                <td>{$admins[$vo['create_by']]}</td>
                                <td>{$vo.remark}</td>
                                <td>
                                    <span>
                                        <a href="{:U('indexadmin/del_user_remark',['id'=>$vo['id']])}" class="js-ajax-delete" data-msg="确定删除它吗？">删除</a>
                                    </span>
                                </td>
                            </tr>
                        </foreach>
                    </table>
                </div>
            </div>
            <div class="control-group">
                <label class="control-label">当前登记人</label>
                <div class="controls">
                    <input type="text" value="{$currentAdmin.user_login}" disabled class="disabled">
                </div>
            </div>
            <div class="control-group">
                <label class="control-label">备注</label>
                <div class="controls">
                    <textarea name="remark" cols="30" rows="3"></textarea>
                </div>
            </div>
        </fieldset>
        <div class="form-actions">
            <input type="hidden" name="id" value="{$data.id}" />
            <button type="submit" class="btn btn-primary js-ajax-submit">提交备注</button>
            <a class="btn" href="javascript:history.back(-1);">{:L('BACK')}</a>
            <!-- <button class="btn js-ajax-close-btn" type="submit">{:L('CLOSE')}</button> -->
        </div>
    </form>
</div>
<script src="__PUBLIC__/js/common.js"></script>
<script>
    $(function() {
        $(".js-ajax-close-btn").on('click', function(e) {
            e.preventDefault();
            Wind.use("artDialog", function() {
                art.dialog({
                    id : "question",
                    icon : "question",
                    fixed : true,
                    lock : true,
                    background : "#CCCCCC",
                    opacity : 0,
                    content : "您确定需要关闭当前页面嘛？",
                    ok : function() {
                        setCookie('refersh_time_admin_menu_index', 1);
                        window.close();
                        return true;
                    }
                });
            });
        });
    });
</script>
</body>
</html>